<template>
  <div>
  <ul>
   <li v-for="(item,index) in people" :key="index">{{ item }}</li>
  </ul>
  <button @click="go">走一走</button>
  </div>
</template>

<script>
export default {
 data() {
  return{
   people:['帅哥','美女','程序猿']
  }
 },
 methods: {
  go() {
   // this.people.unshift(this.people[1])
   this.people.push(this.people[0])
   this.people.shift(this.people[0])
  }
 }
}
</script>

<style>

</style>